{
  "version": "2.0.0",
  "tasks": [
    {
      "type": "shell",
      "label": "Build (Debug)",
      "command": "${input:compilerPath}",
      "args": [
        "-fdiagnostics-color=always",
        "-g",
        "-I",
        "${input:includePath}",
        "-L",
        "${input:libraryPath}",
        "${workspaceFolder}/src/*.c",
        "-o",
        "${workspaceFolder}/${input:executableName}",
        "${input:linkerFlags}"
      ],
      "options": {
        "cwd": "${workspaceFolder}"
      },
      "problemMatcher": [
        "$gcc"
      ],
      "group": {
        "kind": "build",
        "isDefault": true
      }
    },
    {
      "type": "shell",
      "label": "Release",
      "command": "${input:compilerPath}",
      "args": [
        "-fdiagnostics-color=always",
        "-O3",
        "-I",
        "${input:includePath}",
        "-L",
        "${input:libraryPath}",
        "${workspaceFolder}/src/*.c",
        "-o",
        "${workspaceFolder}/${input:executableName}",
        "${input:linkerFlags}"
      ],
      "options": {
        "cwd": "${workspaceFolder}"
      },
      "problemMatcher": [
        "$gcc"
      ],
      "group": {
        "kind": "build",
        "isDefault": true
      },
    }
  ],
  "inputs": [
    {
      "id": "executableName",
      "type": "command",
      "command": "cpptools.activeConfigCustomVariable",
      "args": "executableName"
    },
    {
      "id": "compilerPath",
      "type": "command",
      "command": "cpptools.activeConfigCustomVariable",
      "args": "compilerPath"
    },
    {
      "id": "includePath",
      "type": "command",
      "command": "cpptools.activeConfigCustomVariable",
      "args": "includePath"
    },
    {
      "id": "libraryPath",
      "type": "command",
      "command": "cpptools.activeConfigCustomVariable",
      "args": "libraryPath"
    },
    {
      "id": "linkerFlags",
      "type": "command",
      "command": "cpptools.activeConfigCustomVariable",
      "args": "linkerFlags"
    }
  ]
}